//
//  SuggestVC.m
//  hnGovernment
//
//  Created by 安仔 on 17/3/6.
//  Copyright © 2017年 安仔. All rights reserved.
//

#import "SuggestVC.h"
#import "GXJTextField.h"
#import "XJTextView.h"


@interface SuggestVC ()

@property (nonatomic, strong) GXJTextField * titleTF;
@property (nonatomic, strong) XJTextView *contentTextView;

@end

@implementation SuggestVC

- (void)viewDidLoad {
    [super viewDidLoad];
    
    self.view.backgroundColor = RGB(243, 243, 243);
    self.title = NSLocalString(@"我的建议");
    
    UIBarButtonItem *rightbuttonItem = [[UIBarButtonItem alloc]initWithTitle:@"发送" style:UIBarButtonItemStylePlain target:self action:@selector(rightFun)];
    [rightbuttonItem setTitleTextAttributes:@{NSForegroundColorAttributeName : [UIColor whiteColor]} forState:UIControlStateNormal];
    self.navigationItem.rightBarButtonItem = rightbuttonItem;
    
    [self createSuggestView];

}

- (void) rightFun {
    NSLog(@"123");
}

- (void)createSuggestView {

    UIView *bottomView = [[UIView alloc] initWithFrame:CGRectMake(40 * m6Scale, 20 * m6Scale, 670 * m6Scale, 480 * m6Scale)];
     bottomView.layer.cornerRadius = 10 * m6Scale;
    bottomView.backgroundColor = [UIColor whiteColor];
    [self.view addSubview:bottomView];
    
    UIView *lineView = [[UIView alloc] initWithFrame:CGRectMake(0, 100 * m6Scale, 670 * m6Scale, 2 * m6Scale)];
    lineView.backgroundColor = APPColor;
    [bottomView addSubview:lineView];
    
    self.titleTF = [[GXJTextField alloc] initWithFrame:CGRectMake(0, 2 * m6Scale, 670 * m6Scale, 98 * m6Scale)];
    self.titleTF.placeholder = NSLocalString(@"请输入标题");
    self.titleTF.font = 32 * m6Scale;
    [bottomView addSubview:self.titleTF];
    
    self.contentTextView = [[XJTextView alloc] initWithFrame:CGRectMake(0, 102 * m6Scale, 670 * m6Scale, 360 * m6Scale)];
    self.contentTextView.placeholder = NSLocalString(@"请输入正文");
    self.contentTextView.font = [UIFont systemFontOfSize:24 * m6Scale];
    [bottomView addSubview:self.contentTextView];

}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}



@end
